/** <a href="http://www.cpupk.com/decompiler">Eclipse Class Decompiler</a> plugin, Copyright (c) 2017 Chen Chao. **/
package com.minierp.controller;

import com.minierp.bean.GatherBillBean;
import com.minierp.bean.GatherBillItemBean;
import com.minierp.bean.QueryParameterBean;
import com.minierp.bean.QueryResult;
import com.minierp.bean.UserBean;
import com.minierp.dao.CodeRuleDao;
import com.minierp.dao.CooperBillItemDao;
import com.minierp.dao.DepartmentDao;
import com.minierp.dao.GatherBillDao;
import com.minierp.dao.GatherBillItemDao;
import com.minierp.dao.IdGenerator;
import com.minierp.dao.MakeTypeDao;
import com.minierp.dao.QueryDao;
import com.minierp.dao.SerialNumberDao;
import com.minierp.dao.TallySetDao;
import com.minierp.err.NotAllowException;
import com.minierp.err.PermissionDennyException;
import com.minierp.helper.EncCommonHelper;
import com.minierp.helper.EncGatherBillMACtrHelper;
import com.minierp.helper.PageHelper;
import com.minierp.model.CodeRule;
import com.minierp.model.CooperBill;
import com.minierp.model.CooperBillItem;
import com.minierp.model.Department;
import com.minierp.model.Establishment;
import com.minierp.model.GatherBill;
import com.minierp.model.GatherBillItem;
import com.minierp.model.MakeType;
import com.minierp.model.TallySet;
import com.minierp.service.GatherBillService;
import com.minierp.view.GatherBillListForAccountExcelView;
import java.math.BigDecimal;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.sql.DataSource;
import org.springframework.dao.CannotAcquireLockException;
import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.multiaction.MultiActionController;

public class GatherBillMACtr extends MultiActionController {
	private String dialogSuccessView;
	private String listForExamineView;
	private String infoForExamineView;
	private String listForUnExamineView;
	private String infoForUnExamineView;
	private String listForCancelView;
	private String infoForCancelView;
	private String searchResultView;
	private String itemListForCooperBillView;
	private String printView;
	private String printCostView;
	private String listForAccountFormView;
	private String listForAccountView;
	private CooperBillItemDao cooperBillItemDao;
	private GatherBillDao gatherBillDao;
	private GatherBillItemDao gatherBillItemDao;
	private DepartmentDao departmentDao;
	private MakeTypeDao makeTypeDao;
	private TallySetDao tallySetDao;
	private QueryDao queryDao;
	private CodeRuleDao codeRuleDao;
	private SerialNumberDao serialNumberDao;
	private IdGenerator idGenerator;
	private GatherBillService gatherBillService;
	private DataSource dataSource;

	public ModelAndView handleSearchResult(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		if (!EncCommonHelper.checkPrivilege(request, "GATH_BILL_SEAR")) {
			throw new PermissionDennyException("Permission Denny");
		} else {
			ModelAndView mv = new ModelAndView(this.searchResultView);
			QueryParameterBean b = EncGatherBillMACtrHelper.handleSearchResult(
					request, this.dataSource);
			QueryResult qr = this.queryDao.doQuery(b.getCurrentPage(),
					b.getPageSize(), b.getQParas(), b.getOParas(),
					(String[]) null, b.getShortNameMap(), b.getRetObjs(),
					(String[]) null);
			mv.addObject("qr", qr);
			mv.addAllObjects(b.getParameters());
			mv.addObject("departmentList", this.departmentDao.getList(true));
			UserBean ub = EncCommonHelper.getCurrentUserAccount(request);
			mv.addObject("tsList",
					PageHelper.getTallySetList(this.tallySetDao, ub));
			return mv;
		}
	}

	public ModelAndView handleExamine(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		ModelAndView mv = new ModelAndView(this.dialogSuccessView);
		UserBean ub = EncCommonHelper.getCurrentUserAccount(request);
		String idStr = request.getParameter("id_str");
		String flag = request.getParameter("flag");
		boolean examined = false;
		if (flag != null && flag.equals("1")) {
			examined = true;
		}

		String[] arr = idStr.split(";");
		boolean num = false;
		String msg;
		byte arg18;
		if (!examined) {
			if (!EncCommonHelper.checkPrivilege(request, "GATH_UN_EXAM")) {
				throw new Exception("Permission deny!");
			}

			try {
				for (int examinerId = 0; examinerId < arr.length; ++examinerId) {
					this.gatherBillService.txUnExamine(
							Long.parseLong(arr[examinerId]),
							this.gatherBillDao, this.gatherBillItemDao,
							this.cooperBillItemDao);
				}

				msg = "反审核成功";
			} catch (CannotAcquireLockException arg16) {
				msg = "事务冲突故障，请重新操作！";
			} catch (NotAllowException arg17) {
				msg = arg17.getMessage();
			}

			arg18 = 1;
		} else {
			if (!EncCommonHelper.checkPrivilege(request, "GATH_EXAM")) {
				throw new Exception("Permission deny!");
			}

			long arg19 = ub.getStaffer().getId();
			String examinerName = ub.getStaffer().getStafferName();

			try {
				for (int w = 0; w < arr.length; ++w) {
					this.gatherBillService.txExamine(Long.parseLong(arr[w]),
							this.gatherBillDao, this.gatherBillItemDao,
							this.cooperBillItemDao, arg19, examinerName);
				}

				msg = "审核成功";
			} catch (CannotAcquireLockException arg14) {
				msg = "事务冲突故障，请重新操作！";
			} catch (NotAllowException arg15) {
				msg = arg15.getMessage();
			}

			arg18 = 1;
		}

		mv.addObject("returnValue", String.valueOf(arg18));
		EncCommonHelper.setAlertMessage(request, msg);
		return mv;
	}

	public ModelAndView handleListForExamine(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		if (!EncCommonHelper.checkPrivilege(request, "GATH_EXAM")) {
			throw new PermissionDennyException("Permission Denny");
		} else {
			ModelAndView mv = new ModelAndView(this.listForExamineView);
			String searchKey = request.getParameter("search_key");
			String tsId = request.getParameter("ts_id");
			UserBean ub = EncCommonHelper.getCurrentUserAccount(request);
			if (tsId == null || tsId.equals("")) {
				tsId = String.valueOf(ub.getUser().getDfTsId());
			}

			List tsList = PageHelper.getTallySetList(this.tallySetDao, ub);
			long managerId = 0L;
			if (EncCommonHelper.checkPurePrivilege(request, "BUSI_SELF")) {
				managerId = ub.getStaffer().getId();
			}

			Date allowStart = null;
			if (EncCommonHelper.checkPurePrivilege(request, "NO_EARL_DATA")) {
				allowStart = EncCommonHelper.getEarlDataDate(request);
			}

			int perPageNum = EncCommonHelper.getPageSize(request);
			int total = this.gatherBillDao.getListCount(searchKey, false,
					Long.parseLong(tsId), managerId, ub, allowStart);
			int pageno = EncCommonHelper.getCurrentPageIndex(request, total,
					perPageNum);
			int startIndex = (pageno - 1) * perPageNum;
			List list = this.gatherBillDao.getList(searchKey, false,
					Long.parseLong(tsId), managerId, ub, allowStart,
					startIndex, perPageNum);
			mv.addObject("qr", EncCommonHelper.parseQueryResult(list, total,
					perPageNum, pageno));
			mv.addObject("searchKey", searchKey);
			mv.addObject("tsId", tsId);
			mv.addObject("tsList", tsList);
			return mv;
		}
	}

	public ModelAndView handleInfoForExamine(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		ModelAndView mv = new ModelAndView(this.infoForExamineView);
		String id = request.getParameter("id");
		mv.addObject("record", this.getGatherBill(Long.parseLong(id), false));
		return mv;
	}

	public ModelAndView handleListForUnExamine(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		if (!EncCommonHelper.checkPrivilege(request, "GATH_UN_EXAM")) {
			throw new PermissionDennyException("Permission Denny");
		} else {
			ModelAndView mv = new ModelAndView(this.listForUnExamineView);
			String searchKey = request.getParameter("search_key");
			String tsId = request.getParameter("ts_id");
			UserBean ub = EncCommonHelper.getCurrentUserAccount(request);
			if (tsId == null || tsId.equals("")) {
				tsId = String.valueOf(ub.getUser().getDfTsId());
			}

			List tsList = PageHelper.getTallySetList(this.tallySetDao, ub);
			long managerId = 0L;
			if (EncCommonHelper.checkPurePrivilege(request, "BUSI_SELF")) {
				managerId = ub.getStaffer().getId();
			}

			Date allowStart = null;
			if (EncCommonHelper.checkPurePrivilege(request, "NO_EARL_DATA")) {
				allowStart = EncCommonHelper.getEarlDataDate(request);
			}

			int perPageNum = EncCommonHelper.getPageSize(request);
			int total = this.gatherBillDao.getListCount(searchKey, true,
					Long.parseLong(tsId), managerId, ub, allowStart);
			int pageno = EncCommonHelper.getCurrentPageIndex(request, total,
					perPageNum);
			int startIndex = (pageno - 1) * perPageNum;
			List list = this.gatherBillDao.getList(searchKey, true,
					Long.parseLong(tsId), managerId, ub, allowStart,
					startIndex, perPageNum);
			mv.addObject("qr", EncCommonHelper.parseQueryResult(list, total,
					perPageNum, pageno));
			mv.addObject("searchKey", searchKey);
			mv.addObject("tsId", tsId);
			mv.addObject("tsList", tsList);
			return mv;
		}
	}

	public ModelAndView handleInfoForUnExamine(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		ModelAndView mv = new ModelAndView(this.infoForUnExamineView);
		String id = request.getParameter("id");
		mv.addObject("record", this.getGatherBill(Long.parseLong(id), false));
		return mv;
	}

	public ModelAndView handleListForCancel(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		if (!EncCommonHelper.checkPrivilege(request, "GATH_CANC")) {
			throw new PermissionDennyException("Permission Denny");
		} else {
			ModelAndView mv = new ModelAndView(this.listForCancelView);
			String searchKey = request.getParameter("search_key");
			String tsId = request.getParameter("ts_id");
			UserBean ub = EncCommonHelper.getCurrentUserAccount(request);
			if (tsId == null || tsId.equals("")) {
				tsId = String.valueOf(ub.getUser().getDfTsId());
			}

			List tsList = PageHelper.getTallySetList(this.tallySetDao, ub);
			long managerId = 0L;
			if (EncCommonHelper.checkPurePrivilege(request, "BUSI_SELF")) {
				managerId = ub.getStaffer().getId();
			}

			Date allowStart = null;
			if (EncCommonHelper.checkPurePrivilege(request, "NO_EARL_DATA")) {
				allowStart = EncCommonHelper.getEarlDataDate(request);
			}

			int perPageNum = EncCommonHelper.getPageSize(request);
			int total = this.gatherBillDao.getListCount(searchKey,
					Long.parseLong(tsId), managerId, ub, allowStart);
			int pageno = EncCommonHelper.getCurrentPageIndex(request, total,
					perPageNum);
			int startIndex = (pageno - 1) * perPageNum;
			List list = this.gatherBillDao.getList(searchKey,
					Long.parseLong(tsId), managerId, ub, allowStart, "",
					startIndex, perPageNum);
			mv.addObject("qr", EncCommonHelper.parseQueryResult(list, total,
					perPageNum, pageno));
			mv.addObject("searchKey", searchKey);
			mv.addObject("tsId", tsId);
			mv.addObject("tsList", tsList);
			return mv;
		}
	}

	public ModelAndView handleInfoForCancel(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		ModelAndView mv = new ModelAndView(this.infoForCancelView);
		String id = request.getParameter("id");
		mv.addObject("record", this.getGatherBill(Long.parseLong(id), false));
		return mv;
	}

	public ModelAndView handleCancel(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		ModelAndView mv = new ModelAndView(this.dialogSuccessView);
		UserBean ub = EncCommonHelper.getCurrentUserAccount(request);
		if (!EncCommonHelper.checkPrivilege(request, "GATH_CANC")) {
			throw new Exception("Permission deny!");
		} else {
			String id = request.getParameter("id");
			String reason = request.getParameter("reason");

			String msg;
			try {
				this.gatherBillService.txCancel(Long.parseLong(id), reason,
						this.gatherBillDao, this.gatherBillItemDao,
						this.cooperBillItemDao, ub, this.idGenerator);
				msg = "作废成功";
			} catch (CannotAcquireLockException arg8) {
				msg = "事务冲突故障，请重新操作！";
			}

			mv.addObject("returnValue", id);
			EncCommonHelper.setAlertMessage(request, msg);
			return mv;
		}
	}

	private GatherBillBean getGatherBill(long id, boolean countCost)
			throws Exception {
		GatherBill gatherBill = (GatherBill) this.gatherBillDao.get(
				GatherBill.class, id);
		GatherBillBean form = new GatherBillBean();
		if (gatherBill != null && !gatherBill.getEnabled().equals("N")) {
			CooperBill cooperBill = (CooperBill) this.gatherBillDao.get(
					CooperBill.class, gatherBill.getCooperBillId());
			if (cooperBill == null) {
				throw new Exception("Cooper bill not found for id:"
						+ gatherBill.getCooperBillId());
			} else {
				form.setGatherBill(gatherBill);
				List itemList = this.gatherBillItemDao
						.getListByGatherBill(gatherBill.getId());
				Establishment est = (Establishment) this.gatherBillDao.get(
						Establishment.class, cooperBill.getCooperatorId());
				if (est != null) {
					form.setCooperatorName(est.getEstName());
				}

				TallySet ts = (TallySet) this.gatherBillDao.get(TallySet.class,
						gatherBill.getTallySetId());
				if (ts != null) {
					form.setTallySetName(ts.getTitle());
				}

				if (cooperBill.getDepartmentId() != 0L) {
					Department arr = (Department) this.gatherBillDao.get(
							Department.class, cooperBill.getDepartmentId());
					if (arr != null) {
						form.setDepartmentName(arr.getDepartmentName());
					}
				}

				form.setCbCode(cooperBill.getBillCode());
				form.setManagerName(cooperBill.getManagerName());
				ArrayList arg20 = new ArrayList();
				List bbItemList = this.cooperBillItemDao.getList(cooperBill
						.getId());
				List makeTypeList = this.makeTypeDao.getList(false);
				BigDecimal costTotal = new BigDecimal(0);

				for (int i = 0; i < itemList.size(); ++i) {
					GatherBillItemBean itemBean = new GatherBillItemBean();
					GatherBillItem item = (GatherBillItem) itemList.get(i);
					itemBean.setGatherBillItem(item);

					for (int j = 0; j < bbItemList.size(); ++j) {
						CooperBillItem bbItem = (CooperBillItem) bbItemList
								.get(j);
						if (bbItem.getId() == item.getCbItemId()) {
							itemBean.setMakeTypeName(EncCommonHelper
									.getSimpleObjectName(makeTypeList,
											bbItem.getMakeTypeId()));
							itemBean.setProductName(bbItem.getProName());
							itemBean.setSpecification(bbItem.getSpecification());
							itemBean.setFinishedContent(bbItem
									.getFinishedContent());
							itemBean.setMakeRequire(bbItem.getMakeRequire());
							itemBean.setAmountTotal(bbItem.getAmount());
							itemBean.setPriceType(bbItem.getPriceType());
							if (countCost) {
								itemBean.setUnitPrice(bbItem.getUnitPrice());
								BigDecimal amount = new BigDecimal(0);
								new BigDecimal(0);
								if (bbItem.getPriceType().equals("AMOUNT")) {
									itemBean.setUnit(bbItem.getUnit());
									amount = item.getAmount();
								} else if (bbItem.getPriceType().equals("AREA")) {
									itemBean.setUnit("平方米");
									amount = item.getAmount()
											.multiply(bbItem.getSquareNum())
											.divide(bbItem.getAmount(), 4, 4);
								} else if (bbItem.getPriceType().equals(
										"LENGTH")) {
									if (bbItem.getLengType().equals("M")) {
										itemBean.setUnit("米");
									} else {
										itemBean.setUnit("公分");
									}

									amount = item.getAmount()
											.multiply(bbItem.getSquareNum())
											.divide(bbItem.getAmount(), 4, 4);
								}

								BigDecimal itemCost = amount.multiply(
										bbItem.getUnitPrice()).setScale(2, 4);
								costTotal = costTotal.add(itemCost);
								itemBean.setAmountStr(EncCommonHelper
										.parseBigDecimal(amount));
								itemBean.setCost(itemCost);
							} else if (bbItem.getPriceType().equals("AMOUNT")) {
								itemBean.setUnit(bbItem.getUnit());
							} else if (bbItem.getPriceType().equals("AREA")) {
								itemBean.setUnit(this.getUnit(makeTypeList,
										bbItem.getMakeTypeId()));
							} else if (bbItem.getPriceType().equals("LENGTH")) {
								itemBean.setUnit(this.getUnit(makeTypeList,
										bbItem.getMakeTypeId()));
							}
							break;
						}
					}

					arg20.add(itemBean);
				}

				form.setCost(costTotal);
				form.setItems(arg20);
				return form;
			}
		} else {
			throw new Exception("Record not found or enabled for id:" + id);
		}
	}

	private String getUnit(List<?> makeTypeList, long makeTypeId) {
		String unit = "";
		if (makeTypeId != 0L) {
			for (int j = 0; j < makeTypeList.size(); ++j) {
				MakeType p = (MakeType) makeTypeList.get(j);
				if (p.getId() == makeTypeId) {
					unit = p.getUnit();
					break;
				}
			}
		}

		return unit;
	}

	public ModelAndView handleItemListForCooperBill(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		ModelAndView mv = new ModelAndView(this.itemListForCooperBillView);
		String id = request.getParameter("id");
		List items = this.gatherBillItemDao.getListByCooperBill(Long
				.parseLong(id));
		List makeTypeList = this.makeTypeDao.getList(false);

		for (int i = 0; i < items.size(); ++i) {
			Object[] objs = (Object[]) items.get(i);
			GatherBillItemBean itemBean = new GatherBillItemBean();
			GatherBillItem item = (GatherBillItem) objs[1];
			CooperBillItem bbItem = (CooperBillItem) objs[2];
			itemBean.setGatherBillItem(item);
			itemBean.setMakeTypeName(EncCommonHelper.getSimpleObjectName(
					makeTypeList, bbItem.getMakeTypeId()));
			itemBean.setProductName(bbItem.getProName());
			itemBean.setSpecification(bbItem.getSpecification());
			itemBean.setFinishedContent(bbItem.getFinishedContent());
			itemBean.setMakeRequire(bbItem.getMakeRequire());
			itemBean.setAmountTotal(bbItem.getAmount());
			objs[1] = itemBean;
		}

		mv.addObject("items", items);
		return mv;
	}

	public ModelAndView handlePrint(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		String id = request.getParameter("id");
		String printCost = request.getParameter("print_cost");
		ModelAndView mv;
		if (printCost != null && printCost.equals("1")) {
			mv = new ModelAndView(this.printCostView);
			mv.addObject("record", this.getGatherBill(Long.parseLong(id), true));
		} else {
			mv = new ModelAndView(this.printView);
			mv.addObject("record",
					this.getGatherBill(Long.parseLong(id), false));
		}

		mv.addObject("codeRule", this.codeRuleDao.get("GATHER_BILL"));
		return mv;
	}

	public ModelAndView handleBatchNew(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		ModelAndView mv = new ModelAndView(this.dialogSuccessView);
		UserBean ub = EncCommonHelper.getCurrentUserAccount(request);
		CodeRule dbCr = this.codeRuleDao.get("GATHER_BILL");
		String idStr = request.getParameter("coo_id_str");
		String[] idArr = idStr.split(";");
		String msg = "收货信息保存成功";

		try {
			this.gatherBillService.txInsertBatch(idArr, ub, dbCr,
					this.gatherBillDao, this.gatherBillItemDao,
					this.cooperBillItemDao, this.serialNumberDao,
					this.idGenerator);
		} catch (NotAllowException arg9) {
			msg = arg9.getMessage();
		} catch (CannotAcquireLockException arg10) {
			msg = "事务冲突故障，请重新操作！";
		}

		mv.addObject("returnValue", String.valueOf(idArr.length));
		EncCommonHelper.setAlertMessage(request, msg);
		return mv;
	}

	public ModelAndView handleListForAccountForm(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		if (!EncCommonHelper.checkPrivilege(request, "DELI_ACCO")) {
			throw new PermissionDennyException("Permission Denny");
		} else {
			Date now = new Date();
			SimpleDateFormat dateSf = new SimpleDateFormat("yyyy-MM-dd");
			String endDate = dateSf.format(now);
			return (new ModelAndView(this.listForAccountFormView)).addObject(
					"end_date", endDate);
		}
	}

	public ModelAndView handleListForAccount(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		String contentType = request.getParameter("content_type");
		String cooperatorId = request.getParameter("cooperator_id");
		Establishment est = (Establishment) this.gatherBillDao.get(
				Establishment.class, Long.parseLong(cooperatorId));
		ModelAndView mv = new ModelAndView(this.listForAccountView);
		QueryParameterBean b = EncGatherBillMACtrHelper
				.handleListForAccountList(request, this.dataSource);
		mv.addAllObjects(b.getParameters());
		QueryResult qr = this.queryDao.doQuery(b.getQParas(), b.getOParas(),
				(String[]) null, b.getShortNameMap(), b.getRetObjs(),
				(String[]) null);
		List mtList = this.makeTypeDao.getList(false);
		BigDecimal costTotal = new BigDecimal(0);

		for (int map = 0; map < qr.getList().size(); ++map) {
			Object[] v = (Object[]) qr.getList().get(map);
			CooperBillItem bi = (CooperBillItem) v[0];
			BigDecimal thisAmount = (BigDecimal) v[3];
			new BigDecimal(0);
			BigDecimal amount = new BigDecimal(0);
			if (bi.getPriceType().equals("AMOUNT")) {
				amount = thisAmount;
			} else if (bi.getPriceType().equals("AREA")) {
				amount = thisAmount.multiply(bi.getSquareNum()).divide(
						bi.getAmount(), 4, 4);
			} else if (bi.getPriceType().equals("LENGTH")) {
				amount = thisAmount.multiply(bi.getSquareNum()).divide(
						bi.getAmount(), 4, 4);
			}

			BigDecimal itemCost = amount.multiply(bi.getUnitPrice()).setScale(
					2, 4);
			v[3] = amount;
			v[4] = itemCost;
			costTotal = costTotal.add(itemCost);
		}

		if (contentType != null && contentType.equals("EXCEL")) {
			HashMap arg16 = new HashMap();
			arg16.put("list", qr.getList());
			arg16.put("mtList", mtList);
			arg16.put("est", est);
			arg16.put("costTotal", costTotal);
			arg16.put("start_date", request.getParameter("start_date"));
			arg16.put("end_date", request.getParameter("end_date"));
			GatherBillListForAccountExcelView arg17 = new GatherBillListForAccountExcelView();
			return new ModelAndView(arg17, arg16);
		} else {
			mv.addObject("qr", qr);
			mv.addObject("mtList", mtList);
			mv.addObject("est", est);
			mv.addObject("costTotal", costTotal);
			mv.addObject("codeRule", this.codeRuleDao.get("GATHER_BILL"));
			return mv;
		}
	}

	public GatherBillDao getGatherBillDao() {
		return this.gatherBillDao;
	}

	public void setGatherBillDao(GatherBillDao gatherBillDao) {
		this.gatherBillDao = gatherBillDao;
	}

	public DepartmentDao getDepartmentDao() {
		return this.departmentDao;
	}

	public void setDepartmentDao(DepartmentDao departmentDao) {
		this.departmentDao = departmentDao;
	}

	public QueryDao getQueryDao() {
		return this.queryDao;
	}

	public void setQueryDao(QueryDao queryDao) {
		this.queryDao = queryDao;
	}

	public String getSearchResultView() {
		return this.searchResultView;
	}

	public void setSearchResultView(String searchResultView) {
		this.searchResultView = searchResultView;
	}

	public GatherBillItemDao getGatherBillItemDao() {
		return this.gatherBillItemDao;
	}

	public void setGatherBillItemDao(GatherBillItemDao gatherBillItemDao) {
		this.gatherBillItemDao = gatherBillItemDao;
	}

	public String getDialogSuccessView() {
		return this.dialogSuccessView;
	}

	public void setDialogSuccessView(String dialogSuccessView) {
		this.dialogSuccessView = dialogSuccessView;
	}

	public String getInfoForExamineView() {
		return this.infoForExamineView;
	}

	public void setInfoForExamineView(String infoForExamineView) {
		this.infoForExamineView = infoForExamineView;
	}

	public String getInfoForUnExamineView() {
		return this.infoForUnExamineView;
	}

	public void setInfoForUnExamineView(String infoForUnExamineView) {
		this.infoForUnExamineView = infoForUnExamineView;
	}

	public String getListForExamineView() {
		return this.listForExamineView;
	}

	public void setListForExamineView(String listForExamineView) {
		this.listForExamineView = listForExamineView;
	}

	public String getListForUnExamineView() {
		return this.listForUnExamineView;
	}

	public void setListForUnExamineView(String listForUnExamineView) {
		this.listForUnExamineView = listForUnExamineView;
	}

	public String getItemListForCooperBillView() {
		return this.itemListForCooperBillView;
	}

	public void setItemListForCooperBillView(String itemListForCooperBillView) {
		this.itemListForCooperBillView = itemListForCooperBillView;
	}

	public String getPrintView() {
		return this.printView;
	}

	public void setPrintView(String printView) {
		this.printView = printView;
	}

	public String getInfoForCancelView() {
		return this.infoForCancelView;
	}

	public void setInfoForCancelView(String infoForCancelView) {
		this.infoForCancelView = infoForCancelView;
	}

	public String getListForCancelView() {
		return this.listForCancelView;
	}

	public void setListForCancelView(String listForCancelView) {
		this.listForCancelView = listForCancelView;
	}

	public GatherBillService getGatherBillService() {
		return this.gatherBillService;
	}

	public void setGatherBillService(GatherBillService gatherBillService) {
		this.gatherBillService = gatherBillService;
	}

	public DataSource getDataSource() {
		return this.dataSource;
	}

	public void setDataSource(DataSource dataSource) {
		this.dataSource = dataSource;
	}

	public TallySetDao getTallySetDao() {
		return this.tallySetDao;
	}

	public void setTallySetDao(TallySetDao tallySetDao) {
		this.tallySetDao = tallySetDao;
	}

	public CooperBillItemDao getCooperBillItemDao() {
		return this.cooperBillItemDao;
	}

	public void setCooperBillItemDao(CooperBillItemDao cooperBillItemDao) {
		this.cooperBillItemDao = cooperBillItemDao;
	}

	public MakeTypeDao getMakeTypeDao() {
		return this.makeTypeDao;
	}

	public void setMakeTypeDao(MakeTypeDao makeTypeDao) {
		this.makeTypeDao = makeTypeDao;
	}

	public CodeRuleDao getCodeRuleDao() {
		return this.codeRuleDao;
	}

	public void setCodeRuleDao(CodeRuleDao codeRuleDao) {
		this.codeRuleDao = codeRuleDao;
	}

	public IdGenerator getIdGenerator() {
		return this.idGenerator;
	}

	public void setIdGenerator(IdGenerator idGenerator) {
		this.idGenerator = idGenerator;
	}

	public SerialNumberDao getSerialNumberDao() {
		return this.serialNumberDao;
	}

	public void setSerialNumberDao(SerialNumberDao serialNumberDao) {
		this.serialNumberDao = serialNumberDao;
	}

	public String getPrintCostView() {
		return this.printCostView;
	}

	public void setPrintCostView(String printCostView) {
		this.printCostView = printCostView;
	}

	public String getListForAccountFormView() {
		return this.listForAccountFormView;
	}

	public void setListForAccountFormView(String listForAccountFormView) {
		this.listForAccountFormView = listForAccountFormView;
	}

	public String getListForAccountView() {
		return this.listForAccountView;
	}

	public void setListForAccountView(String listForAccountView) {
		this.listForAccountView = listForAccountView;
	}
}